package com.csht.service.Impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.csht.mapper.CshtBrandMapper;
import com.csht.model.CshtBrand;
import com.csht.service.CshtBrandService;
/**
 * 品牌
 * @author chenhuiyan
 *
 */
@Service
public class CshtBrandServiceImpl implements CshtBrandService {
	
	@Autowired
	private CshtBrandMapper cshtBrandMapper;

	/**
	 * 热点元素&高端品牌
	 */
	@Override
	public List<CshtBrand> getAllBrand(Integer oneMenuId) throws Exception {
		List<CshtBrand> cshtBrandList = cshtBrandMapper.getAllBrand(oneMenuId);
		return cshtBrandList;
	}

	/**
	 * 根据品牌id查找品牌
	 */
	@Override
	public CshtBrand getBrandById(Integer brandId) throws Exception {
		CshtBrand cshtBrand = cshtBrandMapper.getBrandById(brandId);
		return cshtBrand;
	}

}
